<?php
/**
 * Created by PhpStorm.
 * User: Administrator
 * Date: 2019/2/28 0028
 * Time: 14:51
 */
include "config.php";

$uid = $_REQUEST["uId"];
$sql = "SELECT * FROM `cartinfo` WHERE uid = ".$uid;
$result = $conn->query($sql);
$resultArr = array(); 
while ($row=$result->fetch_assoc()){
    array_push($resultArr,$row);
}
print_r(json_encode($resultArr));
$conn->close();